package com.chixing.day04.homework;

/**
 * @author Y2014188432
 */
public class OrderTest {
    public static void main(String[] args) {
        // 创建测试对象类 order1 order2 order3
        Order order1 =   new Order("8384933",4500);
        Order order2 =   new Order("7834833",4000);
        Order order3 =   new Order("3834833",678);
        // 对订单进行分割
        Order[] orders1 = OrderProcess.process(order1);
        Order[] orders2 = OrderProcess.process(order2);
        Order[] orders3 = OrderProcess.process(order3);
        // 通过迭代器查看分割后的订单数组
        System.out.println("==========\t\torder1\t\t==========");
        for (Order s:orders1) {
            System.out.println(s.toString());
        }
        System.out.println("==========\t\torder2\t\t==========");
        for (Order s:orders2) {
            System.out.println(s.toString());
        }
        System.out.println("==========\t\torder3\t\t==========");
        for (Order s:orders3) {
            System.out.println(s.toString());
        }
    }
}
